<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ taglib uri="/struts-tags" prefix="s" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/sys/regedit/";  //应用的地址名
String addActionName = path+request.getAttribute("REQUEST_PATH")+"?op=savejs";
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    
    <title>系统注册表添加</title>
<script type="text/javascript">
<!--
           $(function(){
               //初始化工作，因为远程载入该界面时无法通过在标签中进行设置相应的验证属性等信息，必须要在这里进行初始化
               //$('#add').linkbutton();
               $('#vcProject').validatebox({
                   required:'true',
                   missingMessage:'必须输入所属项目名称',
                   validType:'length[1,50]&specialChar'
               });
               $('#vcModule').validatebox({
                   required:'true',
                   missingMessage:'必须输入主模块名',
                   validType:'length[1,50]&specialChar'
               });
               $('#vcItem').validatebox({
                   required:'true',
                   missingMessage:'必须输入功能项目名称',
                   validType:'length[1,50]&specialChar'
               });
               $('#vcName').validatebox({
                   required:'true',
                   missingMessage:'必须输入键名',
                   validType:'length[1,50]'
               });
               $('#vcValue').validatebox({
                   required:'true',
                   missingMessage:'必须输入键值',
                   validType:'length[1,2000]'
               });
               $('#vcNote').validatebox({
                   validType:'length[1,2000]'
               });
	           //点击添加按钮操作
			   $('#addBtn').click(function(){
                  $('#editForm').submit();
	            });
	            //表单验证及提交处理操作
	           $('#editForm').form({
			        url:'<%=addActionName%>',
			        onSubmit: function(){
			            if($(this).form('validate')){
			                 $.util.showLoading();
			                 $('#operateWindow').window('close');
                            return true;
			             }else{
			                return false;
			             }
			        },
			        success:function(data){
			            $.util.removeLoading();
                        returnOptMsg(data);
			        }
				});
	            
           });
//-->
</script>
</head>
<body bgcolor="#FFFFFF" text="#000000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" >
 <s:form action="editForm" method="post">
 <s:hidden id="vcId"  name="po.vcId"></s:hidden>
 <s:hidden id="vcDelFlag"  name="po.vcDelFlag"></s:hidden>
<table align="center" class="tb_add_th" width="100%">
<tr><th align="left">所属项目名称:</th><td><s:textfield id="vcProject" name="po.vcProject" style="width:200px"/><font color="red">*</font></td></tr>
<tr><th align="left">主模块名称:</th><td><s:textfield id="vcModule" name="po.vcModule" style="width:200px"/><font color="red">*</font></td></tr>
<tr><th align="left">功能项目名称:</th><td><s:textfield id="vcItem" name="po.vcItem" style="width:200px"/><font color="red">*</font></td></tr>
<tr><th align="left">键名:</th><td><s:textfield id="vcName" name="po.vcName" style="width:200px"/><font color="red">*</font></td></tr>
<tr><th align="left">键值:</th><td><s:textfield id="vcValue" name="po.vcValue" style="width:200px"/><font color="red">*</font></td></tr>
<tr><th align="left">备注说明:</th><td><s:textarea id="vcNote" name="po.vcNote" rows="3" style="width:200px;height:60px"></s:textarea></td></tr>
</table>
</s:form>
</body>
</html>


